package org.gangcai.mac.shop.bean;

import com.google.gson.internal.bind.util.ISO8601Utils;

/**
 * Created by mac on 2018/4/1.
 */

public class StepItem {

    private int leftIconUnCeritify;
    private boolean isCeritify;
    String rightTips;
    String msg;
    int leftIcon;

    /***
     * 1已认证 2认证失败3已填写4未填写
     * @param state
     * @param msg
     * @param leftIcon
     * @param leftIconUnCeritify
     */
    public StepItem(int state, String msg, int leftIcon, int leftIconUnCeritify) {
        if (state == 1) {
            this.rightTips = "已认证";
        } else if (state == 2) {
            this.rightTips = "认证失败";
        } else if (state == 3) {
            this.rightTips = "已填写";
        } else {
            this.rightTips = "去填写";
        }
        this.isCeritify = state == 1;
        this.msg = msg;
        this.leftIcon = leftIcon;
        this.leftIconUnCeritify = leftIconUnCeritify;
    }

    public String getRightTips() {
        return rightTips;
    }

    public void setRightTips(String rightTips) {
        this.rightTips = rightTips;
    }

    public String getMsg() {
        return msg;
    }

    public void setMsg(String msg) {
        this.msg = msg;
    }

    public int getLeftIcon() {
        if (this.isCeritify) {

            return leftIcon;
        } else {
            return leftIconUnCeritify;
        }
    }

    public void setLeftIcon(int leftIcon) {
        this.leftIcon = leftIcon;
    }

   /* @Deprecated
    public StepItem(String rightTips, String msg, int leftIcon) {
        this.rightTips = rightTips;
        this.msg = msg;
        this.leftIcon = leftIcon;
    }*/

    public boolean isCeritify() {
        return isCeritify;
    }
}
